package com.wjbgn.electronicnian.entity;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * Description:
 * Create Date: 2022-01-20T11:06:12.872423800
 *
 * @author weirx
 * @version 1.0
 */
@Data
@TableName(value = "nian_dumplings")
public class NianDumplingsDO {

    /**
     *
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    public NianDumplingsDO() {

    }


    public NianDumplingsDO(Long id, Integer dumplingsNum) {
        this.id = id;
        this.dumplingsNum = dumplingsNum;
    }

    public NianDumplingsDO(Long nianId) {
        this.nianId = nianId;
    }

    public NianDumplingsDO(Long nianId, String dumplingsName, Integer hungryNum, Integer dumplingsNum) {
        this.nianId = nianId;
        this.dumplingsName = dumplingsName;
        this.hungryNum = hungryNum;
        this.dumplingsNum = dumplingsNum;
    }

    public NianDumplingsDO(Long nianId, String dumplingsName) {
        this.nianId = nianId;
        this.dumplingsName = dumplingsName;
    }

    /**
     * 年兽id
     */
    private Long nianId;
    /**
     * 饺子名字
     */
    private String dumplingsName;

    /**
     * 饺子饥饿值
     */
    private Integer hungryNum;

    /**
     * 饺子数量
     */
    private Integer dumplingsNum;

    /**
     * 创建时间
     */
    @TableField(fill = FieldFill.INSERT)
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    /**
     * 更新时间
     */
    @TableField(fill = FieldFill.INSERT_UPDATE)
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    /**
     * 是否删除 1：是  0否
     */
    private Integer isDelete;

}
